using System;
using digit.Core;
using System.Data;

namespace SMS.ServiceManager
{
    public class ServicesInfo
    {
        #region CONSTRUCTORS
        public ServicesInfo()
        {
            this.m_serviceID = Util.NULL_LONG;
            this.m_serviceName = Util.NULL_STRING;
            this.m_serviceBackup = Util.NULL_STRING;
            this.m_serviceIndex = Util.NULL_BYTE;
            this.m_serviceNumber = Util.NULL_STRING;
            this.m_status = Util.NULL_BYTE;
        }
        public ServicesInfo(long serviceID, string serviceName, string serviceBackup, byte serviceIndex, string serviceNumber, byte status)
        {
            this.m_serviceID = serviceID;
            this.m_serviceName = serviceName;
            this.m_serviceBackup = serviceBackup;
            this.m_serviceIndex = serviceIndex;
            this.m_serviceNumber = serviceNumber;
            this.m_status = status;
        }
        public ServicesInfo(DataRow dRow)
        {
            this.m_serviceID = (long)Util.ReplaceDBNullTo(dRow["serviceID"], Util.NULL_LONG);
            this.m_serviceName = Util.ReplaceDBNullTo(dRow["serviceName"], Util.NULL_STRING).ToString();
            this.m_serviceBackup = Util.ReplaceDBNullTo(dRow["serviceBackup"], Util.NULL_STRING).ToString();
            this.m_serviceIndex = (byte)Util.ReplaceDBNullTo(dRow["serviceIndex"], Util.NULL_BYTE);
            this.m_serviceNumber = Util.ReplaceDBNullTo(dRow["serviceNumber"], Util.NULL_STRING).ToString();
            this.m_status = (byte)Util.ReplaceDBNullTo(dRow["status"], Util.NULL_BYTE);
        }
        #endregion

        #region ATTRIBUTES
        private long m_serviceID;
        private string m_serviceName;
        private string m_serviceBackup;
        private byte m_serviceIndex;
        private string m_serviceNumber;
        private byte m_status;
        #endregion

        #region PROPERTIES
        public long ServiceID
        {
            get
            {
                return this.m_serviceID;
            }
            set
            {
                this.m_serviceID = value;
            }
        }

        public string ServiceName
        {
            get
            {
                return this.m_serviceName;
            }
            set
            {
                this.m_serviceName = value;
            }
        }

        public string ServiceBackup
        {
            get
            {
                return this.m_serviceBackup;
            }
            set
            {
                this.m_serviceBackup = value;
            }
        }

        public byte ServiceIndex
        {
            get
            {
                return this.m_serviceIndex;
            }
            set
            {
                this.m_serviceIndex = value;
            }
        }

        public string ServiceNumber
        {
            get
            {
                return this.m_serviceNumber;
            }
            set
            {
                this.m_serviceNumber = value;
            }
        }

        public byte Status
        {
            get
            {
                return this.m_status;
            }
            set
            {
                this.m_status = value;
            }
        }

        #endregion

    }
}